#include<iostream>

using namespace std;
int main(){
    int m;
    while (cin>>m)
    {
        if(90<=m&&m<=100){
            cout<<"A"<<endl;
        }else if(80<=m&&m<=89){
            cout<<"B"<<endl;
        }else if(70<=m&&m<=79){
            cout<<"C"<<endl;
        }else if(60<=m&&m<=69){
            cout<<"D"<<endl;
        }else if(0<=m&&m<=59){
            cout<<"E"<<endl;
        }else cout<<"Score is error!"<<endl;
    }
    
}